export const redirectRefresh = () => {
    // 获取当前页面路径和参数
    const pages = getCurrentPages();
    const currentPage = pages[pages.length - 1];
    const url = `/${currentPage.route}?${Object.entries(currentPage.options).map(([k, v]) => `${k}=${v}`).join('&')}`;

    // 关闭当前页面并重新打开
    uni.redirectTo({
        url: url,
        success: () => {
            uni.showToast({ title: '...', icon: 'loading' });
        }
    });
};